package controller;

import java.awt.Point;

import view.DisplayManager;

import model.Board;

/**
 * Interface for system's controller. The implementing class will handle game's logic  
 */
public interface Controller {

	/**
	 * Returns reference to the game board
	 * @return chess game board
	 */
	public Board getGameBoard();
	
	/**
	 * Gets piece's position, type and team and adds piece with given details
	 * @param position- new piece's position
	 * @param type- new piece's type
	 * @param isFirstPlayer- the player the new piece is assigned to
	 * @return True if could add piece, False if not
	 */
	public boolean addPiece(Point position, String type, boolean isFirstPlayer);

	/**
	 * Clears the game board
	 */
	public void clearBoard();
	
	/**
	 * Returns maximal number of turns in computer-controlled game
	 * @return maximal number of turns allowed
	 */
	public int getMaxTurns();

	/**
	 * Returns maximal pieces allowed for each player in partial game mode
	 * @return maximal piece number in partial game mode for each player
	 */
	public int getMaxPiecesPartialGame();
	
	/**
	 * Sets the display manager to be used during the game
	 * @param displayManager- display manager object to use
	 */
	public void setDisplayManager(DisplayManager displayManager); 
	 
	/**
	 * Get manager for human-controlled game
	 * @return manager object for human-controlled game
	 */
	public HumanControlledGame getHumanControlledGameManager();

	/**
	 * Get manager for computer-controlled game
	 * @return manager object for computer-controlled game
	 */
	public ComputerControlledGame getComputerControlledGameManager();
}